export function parseAudioToMarkdown(blocks) {
  return `<audio src="${blocks.url}"></audio>`.concat('\n');
}

export function parseVideoToMarkdown(blocks) {
  return `<video src="${blocks.url}"></video>`.concat('\n');
}

export function parseTableToMarkdown(blocks) {
  const data = blocks.content;
  let markdownTable = "|  " + data[0].join(" | ") + " |\n";
  markdownTable += "|  " + data[0].map(v => `----`).join(" | ") + " |\n";
  for (let i = 1; i < data.length; i++) {
      markdownTable += "| " + data[i].join(" | ") + " |\n";
  }
  return markdownTable
}


